package com.aspose.cells.b.a.b;

import java.awt.Rectangle;

public final class zp {
   private int a;
   private int b;
   private int c;
   private int d;

   public zp() {
      this.a = 0;
      this.b = 0;
      this.c = 0;
      this.d = 0;
   }

   public zp(int var1, int var2, int var3, int var4) {
      this.a = var1;
      this.b = var2;
      this.c = var3;
      this.d = var4;
   }

   public static zp a() {
      return new zp(0, 0, 0, 0);
   }

   public static zp a(int var0, int var1, int var2, int var3) {
      return new zp(var0, var1, var2 - var0, var3 - var1);
   }

   public zs b() {
      return new zs(this.c, this.d);
   }

   public int c() {
      return this.a;
   }

   public int d() {
      return this.b;
   }

   public int e() {
      return this.c;
   }

   public int f() {
      return this.d;
   }

   public int g() {
      return this.a;
   }

   public int h() {
      return this.b;
   }

   public int i() {
      return this.a + this.c;
   }

   public int j() {
      return this.b + this.d;
   }

   public boolean k() {
      return this.d == 0 && this.c == 0 && this.a == 0 && this.b == 0;
   }

   public static zp a(zq var0) {
      int var1 = Math.round(var0.f());
      int var2 = Math.round(var0.g());
      int var3 = Math.round(var0.h());
      int var4 = Math.round(var0.i());
      return new zp(var1, var2, var3, var4);
   }

   public void a(int var1, int var2) {
      this.a -= var1;
      this.b -= var2;
      this.c += var1 * 2;
      this.d += var2 * 2;
   }

   public void a(zs var1) {
      this.c = var1.b();
      this.d = var1.c();
   }

   public void a(int var1) {
      this.a = var1;
   }

   public void b(int var1) {
      this.b = var1;
   }

   public void c(int var1) {
      this.c = var1;
   }

   public void d(int var1) {
      this.d = var1;
   }

   public Rectangle l() {
      return new Rectangle(this.a, this.b, this.c, this.d);
   }

   public int hashCode() {
      return (int)((long)this.a ^ ((long)this.b << 13 | (long)this.b >> 19) ^ ((long)this.c << 26 | (long)this.c >> 6) ^ ((long)this.d << 7 | (long)this.d >> 25));
   }

   public boolean equals(Object obj) {
      return obj instanceof zp && a(this, (zp)obj);
   }

   public static boolean a(zp var0, zp var1) {
      if (var0 == var1) {
         return true;
      } else {
         return var0 != null && var1 != null && var0.a == var1.a && var0.b == var1.b && var0.c == var1.c && var0.d == var1.d;
      }
   }

   public boolean a(zp var1) {
      return var1.a < this.a + this.c && this.a < var1.a + var1.c && var1.b < this.b + this.d && this.b < var1.b + var1.d;
   }

   public String toString() {
      return "{X=" + this.a + ",Y=" + this.b + ",Width=" + this.c + ",Height=" + this.d + "}";
   }
}
